package com.spark.market.service.impl;

import com.spark.market.api.dto.SequenceInfo;
import com.spark.market.common.utils.AssertUtils;
import com.spark.market.service.SequenceCmdCoreService;
import com.spark.market.service.manager.SequenceManager;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;

@Service
public class SequenceCmdCoreServiceImpl implements SequenceCmdCoreService {
    @Resource
    SequenceManager sequenceManager;
    @Override
    public void updateSequenceValue(SequenceInfo sequenceInfo) {
        AssertUtils.isNotNull(sequenceInfo, "sequenceInfo is null");
        sequenceManager.updateSequence(sequenceInfo);
    }
}
